<template>
  <div class="main-box">
    <div class="big-title">
      <img src="../../assets/movies/logo.png" alt="" class="logo" />
      <div class="name">豆瓣电影</div>
      <Button type="warning" size="large" class="button" @click="toBigScreen"
        >大屏展示</Button
      >
      <Button type="warning" size="large" class="button" @click="toMovieList"
        >电影清单</Button
      >
      <Button type="warning" size="large" class="button" @click="toDataOverview"
        >首页</Button
      >
    </div>
    <div class="carousel-box">
      <Carousel
        autoplay
        :autoplay-speed="2000"
        v-model="carouselValue"
        loop
        style="width: 60%; height: 100%; margin: auto"
      >
        <CarouselItem v-for="item in carouselList" :key="item.src">
          <div class="demo-carousel">
            <img :src="item.src" alt="" />
          </div>
        </CarouselItem>
      </Carousel>
    </div>
    <div class="score-box">
      <div
        class="score-box-item demo-card"
        v-for="item in scoreList"
        :key="item.title"
      >
        <!-- <img :src="item.img" alt="" /> -->
        <div class="score-box-item-title">{{ item.title }}</div>
        <div class="score-box-item-value">{{ item.value }}</div>
      </div>
    </div>
    <div class="countDate-box demo-card">
      <div class="countDate-box-title">每月上映</div>
      <DatePicker
        type="year"
        placeholder="Select year"
        style="right: 6%; position: absolute; top: 24px"
        v-model="countDateSelected"
        @on-change="countDateSelectedChange"
        size="large"
      ></DatePicker>
      <div id="countDate_echart"></div>
    </div>
    <div class="type-area-box demo-card">
      <!-- <div class="check-box">
        <div class="check-type-box" style="height: 29%">
          <div class="check-type-name">类型：</div>
          <div class="check-type-items">
            <CheckboxGroup
              v-model="moviesTypeCheckedArr"
              @on-change="moviesTypeCheckedChange"
            >
              <Checkbox
                :label="item.name"
                border
                v-for="item in moviesTypeArr"
                :key="item.name"
              ></Checkbox>
            </CheckboxGroup>
          </div>
        </div>
        <div class="check-type-box" style="height: 71%">
          <div class="check-type-name">区域：</div>
          <div class="check-type-items">
            <CheckboxGroup
              v-model="moviesAreaCheckedArr"
              @on-change="moviesAreaCheckedChange"
            >
              <Checkbox
                :label="item.name"
                border
                v-for="item in moviesAreaArr"
                :key="item.name"
              ></Checkbox>
            </CheckboxGroup>
          </div>
        </div>
      </div> -->
      <div class="type-area-echart-box">
        <div id="type_count_echart" class="type-area-echart"></div>
        <Select
          v-model="moviesAreaSelectArr"
          @on-change="moviesAreaSelectChange"
          multiple
          :max-tag-count="3"
          style="
            left: 17%;
            width: 305px;
            top: 27px;
            position: absolute;
            text-align: left;
          "
        >
          <Option
            v-for="(item, index) in moviesAreaArr"
            :value="item"
            :key="index"
            >{{ item }}</Option
          >
        </Select>
        <div
          style="
            top: 17px;
            position: relative;
            border-left: 1px solid #ddd;
            float: left;
            height: 500px;
          "
        ></div>
        <div id="top_actors_echart" class="type-area-echart"></div>
        <Select
          v-model="moviesTypeSelectArr"
          @on-change="moviesTypeSelectChange"
          multiple
          :max-tag-count="3"
          style="
            left: 68%;
            width: 305px;
            top: 526px;
            position: absolute;
            text-align: left;
            z-index: 10;
          "
        >
          <Option
            v-for="(item, index) in moviesTypeArr"
            :value="item"
            :key="index"
            >{{ item }}</Option
          >
        </Select>
        <div
          id="area_count_echart"
          class="type-area-echart"
          style="width: 100%"
        ></div>
      </div>
    </div>
  </div>
</template>
  
  <script>
import dataOverview from "./dataOverview";
export default {
  ...dataOverview,
};
</script>
<style>
.ivu-select-dropdown-list li {
  display: block !important;
  text-align: left !important;
}
.ivu-checkbox-group-item {
  margin-bottom: 2px;
}
.ivu-checkbox-group {
  text-align: left;
}
.ivu-card-body {
  padding: 0;
}
.ivu-checkbox {
  display: none !important;
}
.ivu-checkbox-wrapper-checked.ivu-checkbox-border {
  background-color: #2d8cf0;
  border-color: #2d8cf0;
  color: #fff;
}
</style>
<style scoped>
h3 {
  margin: 40px 0 0;
}
ul {
  list-style-type: none;
  padding: 0;
}
li {
  display: inline-block;
  margin: 0 10px;
}
a {
  color: #42b983;
}
.main-box {
  padding-top: 80px;
  position: relative;
  width: 100%;
  height: 2800px;
  background-color: #f2f8fc;
}
.card-style {
  border-radius: 20px;
}
.big-title {
  background-color: #fff;
  height: 80px;
  width: 100%;
  position: fixed;
  z-index: 20;
  top: 0px;
}
.big-title .logo {
  display: inline-block;
  width: 40px;
  margin-right: 4%;
  position: absolute;
  top: 20px;
  left: 20%;
}
.big-title .name {
  position: absolute;
  font-size: 32px;
  font-weight: bold;
  line-height: 80px;
  left: 23%;
}
.big-title .button {
  margin-left: 20px;
  float: right;
  font-size: 15px;
  border: none;
  color: #000;
  background-color: #ffd100;
  top: 20px;
  position: relative;
  right: 20%;
}
.carousel-box {
  background-color: #eee;
  position: relative;
  margin: auto;
  width: 100%;
  height: 500px;
}
.demo-carousel {
  width: 100%;
  height: 500px;
  overflow: hidden; /* 防止图片溢出容器 */
  position: relative;
}
.demo-carousel img {
  width: 100%;
  height: 100%;
  object-fit: 100% 100%;
}
.demo-card {
  box-shadow: 1px 1px 10px 1px #77777766;
  background-color: #fff;
  border-radius: 12px;
}
.score-box {
  position: relative;
  margin: auto;
  width: 61.3%;
  height: 135px;
  display: flex;
  text-align: center;
  overflow: hidden;
  justify-content: space-around;
}
.score-box .score-box-item {
  width: 23%;
  height: 80%;
  margin-top: 2%;
}
.score-box .score-box-item > img {
  border-radius: 8px;
  width: 94%;
  height: 73%;
  margin-top: 3%;
}
.score-box .score-box-item-title {
  color: #718096;
  font-weight: bold;
  font-size: 30px;
}
.score-box .score-box-item-value {
  color: coral;
  font-family: fantasy;
  /* font-weight: bold; */
  font-size: 38px;
}
.countDate-box {
  position: relative;
  margin: 0 auto;
  width: 60%;
  height: 500px;
}
.countDate-box .countDate-box-title {
  text-align: left;
  position: relative;
  color: #000;
  font-size: 28px;
  top: 20px;
  font-weight: bold;
  left: 39px;
}
.countDate-box #countDate_echart {
  width: 90%;
  margin: 20px auto;
  height: 400px;
}
.type-area-box {
  position: relative;
  margin: 21px auto 0;
  width: 60%;
  height: 1100px;
}
.type-area-box .type-area-echart-box {
  position: relative;
  margin: 21px auto 0;
  width: 96%;
  height: 1050px;
  overflow: hidden;
}
.type-area-box .type-area-echart-box .type-area-echart {
  float: left;
  width: 49%;
  height: 500px;
}
.type-area-box .check-box {
  margin: auto;
  width: 96%;
  height: 360px;
  border: 1px #cccccc solid;
  position: relative;
  top: 20px;
}
.type-area-box .check-type-box {
  margin: auto;
  width: 96%;
  height: 49.9%;
  position: relative;
  overflow: hidden;
  top: 10px;
}
.type-area-box .check-type-name {
  width: 7%;
  height: 100%;
  float: left;
}
.type-area-box .check-type-items {
  width: 93%;
  height: 100%;
  float: left;
  overflow: hidden;
}
</style>
  